package fr.insee.sicape.format;

import fr.insee.sicape.bean.Reponse;

public class SeparatorFormater implements Formater {

	private String separator, missing;
	
	public SeparatorFormater(){}
	
	@Override
	public String format(Reponse reponse, String code, String chaine) {
		
		return
			reponse.getInfoPassives() +
			separator +
			(code == null ? missing : code) +
			separator +
			chaine +
			"\n"
		;
	}

	public String getSeparator() {
		return separator;
	}

	public void setSeparator(String separator) {
		this.separator = separator;
	}

	public String getMissing() {
		return missing;
	}

	public void setMissing(String missing) {
		this.missing = missing;
	}
}
